#!/bin/sh

fifofile="$$.fifo"

function openpipo(){

    mkfifo ${fifofile}
    exec 6<>${fifofile}
    rm -f ${fifofile}
    return 0
}

function writepipo(){

    echo $* >&6
    return 0

}

function readpipo(){

    timeout 0.2 read -u 6 pipo && echo $pipo
    return 0

}

function closepipo(){
    exec 6>&-
    return 0
}
